package com.ruoyi.system.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.KqytDeptsMapper;
import com.ruoyi.system.domain.KqytDepts;
import com.ruoyi.system.service.IKqytDeptsService;

/**
 * 无功能Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-05-26
 */
@Service
public class KqytDeptsServiceImpl implements IKqytDeptsService 
{
    @Autowired
    private KqytDeptsMapper kqytDeptsMapper;

    /**
     * 查询无功能
     * 
     * @param kqytId 无功能主键
     * @return 无功能
     */
    @Override
    public KqytDepts selectKqytDeptsByKqytId(Long kqytId)
    {
        return kqytDeptsMapper.selectKqytDeptsByKqytId(kqytId);
    }

    /**
     * 查询无功能列表
     * 
     * @param kqytDepts 无功能
     * @return 无功能
     */
    @Override
    public List<KqytDepts> selectKqytDeptsList(KqytDepts kqytDepts)
    {
        return kqytDeptsMapper.selectKqytDeptsList(kqytDepts);
    }

    /**
     * 新增无功能
     * 
     * @param kqytDepts 无功能
     * @return 结果
     */
    @Override
    public int insertKqytDepts(KqytDepts kqytDepts)
    {
        kqytDepts.setCreateTime(DateUtils.getNowDate());
        return kqytDeptsMapper.insertKqytDepts(kqytDepts);
    }

    /**
     * 修改无功能
     * 
     * @param kqytDepts 无功能
     * @return 结果
     */
    @Override
    public int updateKqytDepts(KqytDepts kqytDepts)
    {
        return kqytDeptsMapper.updateKqytDepts(kqytDepts);
    }

    /**
     * 批量删除无功能
     * 
     * @param kqytIds 需要删除的无功能主键
     * @return 结果
     */
    @Override
    public int deleteKqytDeptsByKqytIds(Long[] kqytIds)
    {
        return kqytDeptsMapper.deleteKqytDeptsByKqytIds(kqytIds);
    }

    /**
     * 删除无功能信息
     * 
     * @param kqytId 无功能主键
     * @return 结果
     */
    @Override
    public int deleteKqytDeptsByKqytId(Long kqytId)
    {
        return kqytDeptsMapper.deleteKqytDeptsByKqytId(kqytId);
    }
}
